Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: job handler & space configure plugins #191

Merged
merged 21 commits into from
Aug 30, 2023

Conversation

carlbrugger
Copy link
Contributor

@carlbrugger carlbrugger commented Aug 18, 2023

This PR introduces two new plugins: @flatfile/plugin-job-handler and @flatfile/plugin-space-configure.

Docs ref: FlatFilers/Guides#731

@carlbrugger carlbrugger self-assigned this Aug 18, 2023
plugins/job-handler/package.json Outdated Show resolved Hide resolved
plugins/space-configure/package.json Outdated Show resolved Hide resolved
@carlbrugger carlbrugger marked this pull request as ready for review August 22, 2023 19:32
@socket-security
Copy link

socket-security bot commented Aug 22, 2023

Removed dependencies detected. Learn more about Socket for GitHub ↗︎

🚮 Removed packages: @flatfile/[email protected], [email protected], [email protected]

@ashleygmulligan2
Copy link
Contributor

nice, can i do more than create a workbook when space created?

@ashleygmulligan2 ashleygmulligan2 self-requested a review August 23, 2023 16:19
@ashleygmulligan2
Copy link
Contributor

how does the code look for success/fail on the job? How do i give you the outcome messages etc?

@carlbrugger
Copy link
Contributor Author

nice, can i do more than create a workbook when space created?

configureSpace() takes a partial CreateWorkbookConfig and an optional partial SpaceConfig, so it can create sheets, actions, etc. It specifically listens for space:configure.

@carlbrugger
Copy link
Contributor Author

carlbrugger commented Aug 23, 2023

how does the code look for success/fail on the job? How do i give you the outcome messages etc?

Success is assumed if no error is thrown. To fail the job, throw an exception. The callback can return a Flatfile.JobOutcome (i.e. { info: 'Space configured' } or { outcome: { message: 'Job complete', }, })

Also a tick() function that takes an optional progress and message is passed to the callback to update the job progress.

@ashleygmulligan2
Copy link
Contributor

Do you mind making docs PR at same time? That will help me understand the DXP a lil more

@carlbrugger
Copy link
Contributor Author

Do you mind making docs PR at same time? That will help me understand the DXP a lil more

@ashleygmulligan2 FlatFilers/Guides#731

Copy link
Contributor

@ashleygmulligan2 ashleygmulligan2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

live review

@carlbrugger carlbrugger merged commit 69fd41c into main Aug 30, 2023
2 checks passed
@carlbrugger carlbrugger deleted the feat/job-handler_space-configure branch August 30, 2023 17:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants